package umage.antlr;

import java.util.Collections;
import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Set;

public class InterfaceUnit extends JavaUnit {
	protected String packageName;
	
	protected Set<String> interfaceNames = new HashSet<String>();
	protected Set<String> referencedUnits = new HashSet<String>();
	protected List<FieldUnit> fields = new LinkedList<FieldUnit>();
	protected List<MethodUnit> methods = new LinkedList<MethodUnit>();
	protected List<InterfaceUnit> innerUnits = new LinkedList<InterfaceUnit>();
	
	protected InterfaceUnit() {}
	
	public String getPackage() {
		return packageName;
	}
	
	public Set<String> getInterfaceNames() {
		return Collections.unmodifiableSet(interfaceNames);
	}
	
	public Set<String> getReferencedUnitNames() {
		return Collections.unmodifiableSet(referencedUnits);
	}
	
	public List<FieldUnit> getFields() {
		return Collections.unmodifiableList(fields);
	}
	
	public List<MethodUnit> getMethods() {
		return Collections.unmodifiableList(methods);
	}
	
	public List<InterfaceUnit> getInnerUnits() {
		return Collections.unmodifiableList(innerUnits);
	}
	
}
